import 'package:flutter/foundation.dart';
import 'package:flutter/services.dart';

import 'flutter_device_uuid_platform_interface.dart';

/// An implementation of [FlutterDeviceUuidPlatform] that uses method channels.
class MethodChannelFlutterDeviceUuid extends FlutterDeviceUuidPlatform {
  /// The method channel used to interact with the native platform.
  @visibleForTesting
  final methodChannel = const MethodChannel('flutter_device_uuid');

  @override
  /// 获取设备uuid，iosStoreKey-iOS存储键值
  Future<String?> getDeviceUuid({String? iosStoreKey,}) async {
    final version = await methodChannel.invokeMethod<String>('getDeviceUuid',{"iosStoreKey":iosStoreKey});
    return version;
  }
}
